home *** CD-ROM | disk | FTP | other *** search
/ Programming Languages Suite / ProgramD2.iso / Borland / Borland C++ V5.02 / OWLSRC.PAK / CONTROLB.CPP < prev    next >
Encoding:
C/C++ Source or Header  |  1997-05-06  |  1.5 KB  |  61 lines

  1. //----------------------------------------------------------------------------
  2. // ObjectWindows
  3. // Copyright (c) 1992, 1997 by Borland International, All Rights Reserved
  4. //
  5. //$Revision:   10.6  $
  6. //
  7. // Implementation of class TControlBar.
  8. //----------------------------------------------------------------------------
  9. #include <owl/pch.h>
  10. #if !defined(OWL_CONTROLB_H)
  11. # include <owl/controlb.h>
  12. #endif
  13. #if !defined(WINSYS_UIMETRIC_H)
  14. # include <winsys/uimetric.h>
  15. #endif
  16.  
  17. OWL_DIAGINFO;
  18. DIAG_DECLARE_GROUP(OwlWin);
  19.  
  20. IMPLEMENT_CASTABLE(TControlBar);
  21.  
  22. //
  23. //
  24. //
  25. TControlBar::TControlBar(TWindow*        parent,
  26.                          TTileDirection  direction,
  27.                          TFont*          font,
  28.                          TModule*        module)
  29. :
  30.   TGadgetWindow(parent, direction, font, module)
  31. {
  32.   Margins.Units = TMargins::BorderUnits;
  33.  
  34.  
  35.   Margins.Left = Margins.Right = TUIMetric::CxSizeFrame + 2;  // (6) fixed?
  36.   Margins.Top = Margins.Bottom = TUIMetric::CyFixedFrame;     // (2) fixed?
  37.  
  38.   // Toolbars default to having tooltips 
  39.   //
  40.   WantTooltip = true;
  41.  
  42.   TRACEX(OwlWin, OWL_CDLEVEL, "TControlBar constructed @" << (void*)this);
  43. }
  44.  
  45. //
  46. //
  47. //
  48. TControlBar::~TControlBar()
  49. {
  50.   TRACEX(OwlWin, OWL_CDLEVEL, "TControlBar destructed @" << (void*)this);
  51. }
  52.  
  53. //
  54. //
  55. bool
  56. TControlBar::PreProcessMsg(MSG& msg)
  57. {
  58.   TRACEX(OwlWin, 1, "TControlBar::PreProcessMsg @" << (void*)this);
  59.   return TGadgetWindow::PreProcessMsg(msg);
  60. }
  61.